package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.common.annotation.AutoFill;
import com.ruoyi.common.enums.AutoFillType;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.DispatchMonitoringDataMapper;
import com.ruoyi.system.domain.DispatchMonitoringData;
import com.ruoyi.system.service.IDispatchMonitoringDataService;

/**
 * 监测数据Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-03-02
 */
@Service
public class DispatchMonitoringDataServiceImpl implements IDispatchMonitoringDataService 
{
    @Autowired
    private DispatchMonitoringDataMapper dispatchMonitoringDataMapper;

    /**
     * 查询监测数据
     * 
     * @param monitoringDataId 监测数据主键
     * @return 监测数据
     */
    @Override
    public DispatchMonitoringData selectDispatchMonitoringDataByMonitoringDataId(Long monitoringDataId)
    {
        return dispatchMonitoringDataMapper.selectDispatchMonitoringDataByMonitoringDataId(monitoringDataId);
    }

    /**
     * 查询监测数据列表
     * 
     * @param dispatchMonitoringData 监测数据
     * @return 监测数据
     */
    @Override
    public List<DispatchMonitoringData> selectDispatchMonitoringDataList(DispatchMonitoringData dispatchMonitoringData)
    {
        return dispatchMonitoringDataMapper.selectDispatchMonitoringDataList(dispatchMonitoringData);
    }

    /**
     * 新增监测数据
     * 
     * @param dispatchMonitoringData 监测数据
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.INSERT)
    @Override
    public int insertDispatchMonitoringData(DispatchMonitoringData dispatchMonitoringData)
    {
        return dispatchMonitoringDataMapper.insertDispatchMonitoringData(dispatchMonitoringData);
    }

    /**
     * 修改监测数据
     * 
     * @param dispatchMonitoringData 监测数据
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.UPDATE)
    @Override
    public int updateDispatchMonitoringData(DispatchMonitoringData dispatchMonitoringData)
    {
        return dispatchMonitoringDataMapper.updateDispatchMonitoringData(dispatchMonitoringData);
    }

    /**
     * 批量删除监测数据
     * 
     * @param monitoringDataIds 需要删除的监测数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchMonitoringDataByMonitoringDataIds(Long[] monitoringDataIds)
    {
        return dispatchMonitoringDataMapper.deleteDispatchMonitoringDataByMonitoringDataIds(monitoringDataIds);
    }

    /**
     * 删除监测数据信息
     * 
     * @param monitoringDataId 监测数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchMonitoringDataByMonitoringDataId(Long monitoringDataId)
    {
        return dispatchMonitoringDataMapper.deleteDispatchMonitoringDataByMonitoringDataId(monitoringDataId);
    }
}
